package dao

import "gorm.io/gorm"

type Friend struct {
	gorm.Model
	UserId           int    `json:"userId" gorm:"type:int(10);not null;comment:'用户编号'"`
	FriendId         int    `json:"friendId" gorm:"typ:int(10);not null;comment:'好友编号'"`
	FriendNickName   string `json:"friendNickName" gorm:"type:varchar(30);not null;comment:'好友昵称'"`
	FriendHeardImage string `json:"friendHeardImage" gorm:"type:varchar(255);not null;comment:'好友头像'"`
	Top              int    `json:"top" gorm:"type:tinyint(1);default:0;comment:'0-未置顶1-已置顶'"`
}

type FriendMessage struct {
	gorm.Model
	UserId   int    `json:"userId" gorm:"type:int(10);not null;comment:'用户编号'"`
	FriendId int    `json:"friendId" gorm:"typ:int(10);not null;comment:'好友编号'"`
	Content  string `json:"content" gorm:"type:varchar(255);not null;comment:'消息内容'"`
	Type     int    `json:"type" gorm:"type:tinyint(1);not null;comment:'1-文本2-图片'"`
}
